package com.chen.sysmanagement.controller;

import com.chen.core.model.CommonResponseBean;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * 系统参数查询
 *
 * @author chenguangde
 * @version 1.0
 * @Description
 * @createTime 2021年05月11日 21:08:00
 */
@Slf4j
@RestController
@RequestMapping("/cloud/system/param")
@Tag(name = "系统服务", description = "/cloud/system/param")
public class QueryParameterController {

    @PostMapping("/v1/getParameterById")
    @ResponseBody
    @Operation(summary = "通过Id获取参数")
    public CommonResponseBean<String> getParameterById() {
        CommonResponseBean<String> successResponse = CommonResponseBean.success();
        log.info("通过Id获取参数");
        successResponse.setData("通过Id获取参数成功");
        return successResponse;
    }

    @PostMapping("/v1/getDictById")
    @ResponseBody
    @Operation(summary = "通过Id获取字典")
    public CommonResponseBean<String> getDictById() {
        CommonResponseBean<String> successResponse = CommonResponseBean.success();
        successResponse.setData("通过Id获取字典成功");
        log.info("通过Id获取字典");
        return successResponse;
    }
}
